<?php

namespace App\Console\Commands;

use App\Models\User;
use Illuminate\Console\Command;

class SyncLastActivedAt extends Command {
    protected $signature = 'mychat:sync-last-actived-at';
    protected $description = '将用户最后登录时间从redis同步到数据表中';
    public function handle(User $user) {
        $user->syncLastActivedAt();
        $this->info('同步成功');
    }
}
